Fix #1 for WMF vulnerability
authorTim Starling <tstarling@users.mediawiki.org>
Tue, 3 Jan 2006 00:51:57 +0000 (00:51 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Tue, 3 Jan 2006 00:51:57 +0000 (00:51 +0000)
includes/Linker.php

index d400bef..b9c5d07 100644 (file)
@@ -381,6 +381,10 @@ class Linker {
                global $wgContLang, $wgUser, $wgThumbLimits;
                
                $img   = new Image( $nt );
+               if ( !$img->allowInlineDisplay() ) {
+                       return $this->makeKnownLinkObj( $nt );
+               }
+
                $url   = $img->getViewURL();
                $prefix = $postfix = '';